/*
 * string.h
 *
 *  Created on: 2016-10-1
 *      Author: m
 */

#ifndef SRC_LIB_STRING_H_
#define SRC_LIB_STRING_H_
#include "type.h"

#define TA_FOREGROUND_BLUE      (0x01)
#define TA_FOREGROUND_GREEN     (0x02)
#define TA_FOREGROUND_RED       (0x04)
#define TA_FOREGROUND_INTESITY  (0x08)
#define TA_BACKGROUND_BLUE      (0x10)
#define TA_BACKGROUND_GREEN     (0x20)
#define TA_BACKGROUND_RED       (0x40)
#define TA_BLINKING             (0x80)
#define TA_TEXT_WHITE_B         (TA_FOREGROUND_BLUE | TA_FOREGROUND_GREEN | TA_FOREGROUND_RED | TA_FOREGROUND_INTESITY)
#define TA_TEXT_WHITE           (TA_FOREGROUND_BLUE | TA_FOREGROUND_GREEN | TA_FOREGROUND_RED)

void* memcpy(void *dest, const void *src, unsigned int n);
void memset(void* dst, char c, int len);
void print_char(char c);
int printf(const char* format, ...);
int sprintf(char* buf, const char* format, ...);
int tc_printf(char tmp_text_color, const char* format, ...);
int itoa(int i, int base, int aux, char* buf);
void set_text_attr(char attr);
char get_text_attr();

char* strcpy(char* dest, const char* src);
int strcmp(const char* dest, const char* src);
int strlen(const char * str);
int memcmp(const void *buffer1, const void *buffer2, int count);

void clear_screen();
int isprint(int c);

#endif /* SRC_LIB_STRING_H_ */
